package net.caidingke.shepherd.exception;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * @author bowen.
 */
@Getter
@AllArgsConstructor
public enum ErrorCode {
    ERROR(-1, "服务器异常"),
    NO_PERMISSION(-2, "没有权限"),
    NOT_FOUND(-3, "没有找到"),
    BAD_CREDENTIAL(10001, "用户名或密码错误"),
    USERNAME_EXISTS(10002, "用户名已注册"),
    ACCOUNT_NOT_ACTIVITY(10003, "用户未启用"),

    NO_EXISTS_PERMISSION(20001, "权限不存在");

    private final int code;

    private final String msg;
}
